using System;
using System.Data;
using System.Configuration;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Web.UI.HtmlControls;
using System.ComponentModel;
using System.Collections.Generic;

namespace Controls
{
    public delegate void NewEventHanlder(object sender, EventArgs e);
    /// <summary>
    /// Summary description for SampleCopntrol
    /// </summary>
    public class SampleCopntrol : Control
    {
        private SamplePropertyType sampleProperty_;
        public event NewEventHanlder SampleEvent;
        public SamplePropertyType SampleProperty
        {
            get
            {
                return sampleProperty_;
            }
            set
            {
                sampleProperty_ = value;
            }
        }
	
        public SampleCopntrol()
        {
            //
            // TODO: Add constructor logic here
            //
            if (SampleEvent != null)
            {
                SampleEvent(null, null);
            }
        }

    }
    public class SamplePropertyConverter : StringConverter
    {
        // Methods
        public override TypeConverter.StandardValuesCollection GetStandardValues(ITypeDescriptorContext context)
        {
          
            return base.GetStandardValues(context);
        }

        public override bool GetStandardValuesExclusive(ITypeDescriptorContext context)
        {
            return false;
        }

        public override bool GetStandardValuesSupported(ITypeDescriptorContext context)
        {
            return true;
        }
    }

    public class SamplePropertyType
    {
        private string someVar_;

        public string SomeVar
        {
            get
            {
                return someVar_;
            }
            set
            {
                someVar_ = value;
            }
        }

    }
}